package com.deuwise.system.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
/**
 * 
 *@author deuwise
 *@date 2018-11-06 14:15:04
 */
@Data
@EqualsAndHashCode(callSuper=true)
@TableName("sys_user_role")
public class SysUserRole extends Model<SysUserRole> implements Serializable{
    /**唯一主键*/
    @ApiModelProperty("唯一主键")
    @TableField("id")
    @TableId
    private String id;

    /**用户Id*/
    @ApiModelProperty("用户Id")
    @TableField("user_id")
    private String userId;

    /**角色Id*/
    @ApiModelProperty("角色Id")
    @TableField("role_id")
    private String roleId;

   @Override
    protected Serializable pkVal() {
        return id;
    }
}